import { routerMiddleware } from '../redux_router'
import { configureStore } from '@reduxjs/toolkit'
import reducer from '../reducers/index'
import rootSaga from '../sagas/index'
import logger from 'redux-logger';
import history from 'history/hash';
import createSgaMiddleware from 'redux-saga'
console.log(history);
const sagaMiddleware = createSgaMiddleware()
middlewares=[routerMiddleware(history),sagaMiddleware];
export default store = configureStore({
  reducer: reducer,
  middleware: middlewares,
})
sagaMiddleware.run(rootSaga)
